package com.atguigu.tingshu.album.mapper;

import com.atguigu.tingshu.model.album.BaseCategory1;
import com.atguigu.tingshu.vo.category.CategoryVo;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface BaseCategory1Mapper extends BaseMapper<BaseCategory1> {

    /**
     * 查询分类 MyBatis自动封装
     * @return
     */
    List<CategoryVo> getBaseCategoryList();

    /**
     * 根据一级分类id查询孩子【二级分类+三级分类】
     * @param c1Id
     * @return
     */
    CategoryVo getBaseCategoryListByc1Id(@Param("c1Id") Long c1Id);
}
